<template>
<div>
    <div class="list" v-for="(todo,i) in todos" :key="todo.id">
      <Item 
      :todo="todo"
      :index="i"
      :deleteI="deleteI"
       />
    </div>
</div>
</template>

<script lang="ts">
import { defineComponent, ref } from "vue";
import Item from "./Item.vue";
import { Todo } from "@/types/todo.ts";
export default defineComponent({
  name: "",
  components: { Item },
  props: {
    todos: {
      type: Array as () => Todo[],
      required: true
    },
    deleteI:{
      type:Function,
      required:true
    }
  },
  setup() {
    return {
    };
  }
});
</script>

<style lang="less" scoped>

</style>
